<?php
/**
 * RedCross Application
 *
 * @copyright Copyright (c) 2010, Kristian Stokke Tryggestad, Rune Vikestad, Andreas Flaten Wist, Simen Nicolai Echholt, Ole Henrik Jahren
 */


class Core_Form_User_Email extends RedCross_Form
{
    public function init()
    {
  $this->addElement('text', 'email', array(
      'filters'    => array('StringTrim'),
      'validators'  => array(
    array('StringLength', true, array(6, 60)),
    array('EmailAddress', true),
                array('UniqueEmail', true),
            ),
            'required'   => true,
            'label'   => 'Adresse'
  ));

        $this->addElement('hidden', 'submit_email');
        $this->addElement('submit', 'submit', array(
            'required' => true,
            'ignore'    => true,
            'label'     => 'Legg til epost'
        ));
    }
}
